import request from '@/utils/request'

export function add(data) {
  return request({
    url: 'api/script/saveInfo',
    method: 'post',
    data
  })
}

export function del(ids) {
  return request({
    url: 'api/script/deleteInfo?id=' + ids,
    method: 'get'
  })
}
// 任务详情
export function getScriptDetail(id) {
  return request({
    url: '/api/script/scriptInfo?id=' + id,
    method: 'get'
  })
}
export function edit(data) {
  return request({
    url: 'api/script/saveInfo',
    method: 'post',
    data
  })
}

export default { add, edit, del }
